#ifndef     __DROP_CUP_MOTOR_H
#define     __DROP_CUP_MOTOR_H

#include "../../utils/nocopyable.h"
#include "../../utils/object.h"
#include "../../utils/error.h"

namespace driver {

class DropCupMotor : private utils::NoCopyable {

public:
    enum class Dir : uint8_t {
        CW = 0,
        CCW = 1,
        BRAKE = 2,
    };
    
    static constexpr uint32_t DROP_TIMEOUT = 10 * 1000;

    DropCupMotor();

    utils::Error drop_cup1();
    utils::Error drop_cup2();

    utils::Error drop_cup1_with_check();
    utils::Error drop_cup2_with_check();

private:
    static void set_dir(Dir dir);

};

inline utils::Object<DropCupMotor> dropCupMotor;

}


#endif
